
<template>
 <el-date-picker v-model="row[column.property]" type="date" :format="dates.defaultDatePattern" :value-format="dates.defaultDatePattern"
  :picker-options="dates.pickerOptions.date" @change="dateChanged" />
</template>

<script>
export default {
  name: 'DatePicker',
  props: {
    params: Object,
    renderOpts: Object
  },
  data() {
    return {
      row: null,
      column: null,
    }
  },
  created() {
    this.load()
  },
  methods: {
    async load() {
      const {row, column } = this.params //行、列数据
      this.row = row
      this.column = column
    },
    dateChanged(value) {
      const { row, column } = this
      const cellValue = row[column.property]
    }
  }
}
</script>
